#ifndef _EDGE_LIST_
#define _EDGE_LIST_

#include "edge.h"

typedef struct _EdgeList {
	Edge * edges;
	long length;
} EdgeList;

EdgeList * newEdgeList();

Edge * addEdgeToList(Edge * list, Edge * e);
Edge * addAllEdgesToList(Edge * list, Edge * e);
Edge * removeEdgeFromList(Edge * list, Edge * e);
Edge * removeEdgeByIndex(Edge * list, int index);
int containsEdgeInList(Edge * list, Edge * e);

void printEdgeList(EdgeList * el);
void freeEdges(Edge * list);
void freeEdgeList(EdgeList * el);

void addEdge(EdgeList * el, Edge * e);
void addAllEdges(EdgeList * el1, EdgeList * el2);
void deleteEdge(EdgeList * el, Edge * e);
int containsEdge(EdgeList * el, Edge * e);
void deleteEdgeByIndex(EdgeList * el, int index);
int edgeListContainsPoint(EdgeList * list, Point * p);

#endif
